-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Corrección de falla al intentar cargar imagen de fondo #132
Corrección de falla al intentar cargar imagen de fondo #132
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #132 +/- ##
==========================================
- Coverage 84.53% 84.28% -0.26%
==========================================
Files 9 9
Lines 666 668 +2
Branches 155 155
==========================================
Hits 563 563
- Misses 103 105 +2 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hola @mind-ar
Muchas gracias por el aporte! Ahí dejé una pregunta que me quedó picando.
Sobre el coverage que se está quejando, junto esto del socket es un poco difícil de testear. Igual ya tenemos algunas magias en los tests del run
(no sé si los habías visto).
public/game/index.html
Outdated
socket = io("http://localhost:3000"); | ||
socket = io(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Esto qué onda?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hola, en #133 se permite utilizar cualquier puerto para games, pero en el frontend estaba forzado a localhost:3000
, al dejarlo en blanco toma los datos de la url para iniciar el websocket (sino falla por crossorigin y coso)
Ojo, no sé si esto rompe algun test, si es así puedo buscar alguna alternativa
Este PR corrige un error al intentar cargar la imagen de fondo cuando se conecta con el navegador o se realiza un refresh:
Cambios:
setup()
), envía un mensaje "ready" al backend